package com.rs.game.player.dialogues.impl;

import com.rs.game.player.dialogues.Dialogue;

public class MillieMiller extends Dialogue {
	
	private int npcId = 3806;
	
	@Override
    public void start() {
	sendNPCDialogue(npcId, MAD, "Excuse me, can I help you?");
    }

	@Override
	public void run(int interfaceId, int componentId) {
		if (stage == -1) {
		    sendPlayerDialogue(CONFUSED, "Umm... can you help me?");
		    stage = 0;
		} else if (stage == 0) {
		    sendNPCDialogue(npcId, NORMAL, "Well, depends on what you need help with.");
		    stage = 1;
		} else if (stage == 1) {
		    sendOptionsDialogue(DEFAULT_OPTIONS_TITLE, "I need help finding my way.", "Do you sell anything?", "Bye!");
		    stage = 2;
		} else if (stage == 2) {
		    if (componentId == OPTION_1) {
			sendPlayerDialogue(NORMAL, "I need help finding my way home.");
			end();
		    } else if (componentId == OPTION_2) {
			sendPlayerDialogue(NORMAL, "Do you sell anything?");
			stage = 4;
		    } else {
			stage = 8;
			sendPlayerDialogue(CONFUSED, "Bye!");
		    }
		} else if (stage == 4) {
		    sendNPCDialogue(npcId, NORMAL, "No, I'm sorry.. but I don't.");
		    stage = 5;
		} else if (stage == 5) {
		    sendPlayerDialogue(NORMAL, "Well, that's alright.. I guess I can find somewhere else to go.");
		    stage = 6;
		} else if (stage == 6) {
		    sendNPCDialogue(npcId, NORMAL, "What did you need help with?");
		    stage = 7;
		} else if (stage == 7) {
			sendPlayerDialogue(MAD, "Nothing.. Nevermind");
			stage = 8;
		} else if (stage == 8) {
		    end();
		} else if (stage == 9) {
		    stage = 7;
		    sendNPCDialogue(npcId, NORMAL, "Come back soon, I guess.");
		}
	    }

	    @Override
	    public void finish() {

	    }
	}
